<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>后台管理界面</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
	<link rel="stylesheet" href="css/pintuer.css">
    <link rel="stylesheet" href="css/admin.css">
    <script src="js/jquery.js"></script> 
    <script src="js/pintuer.js"></script>
  </head>
  <body>
   <div class="panel admin-panel">
  <div class="panel-head"><strong><span class="icon-key"></span> 添加用户信息</strong></div>
  <div class="body-content">
    <form method="post" class="form-x" action="AddUser">
      <div class="form-group">
        <div class="label">
          <label for="sitename">手机号：</label>
        </div>
        <div class="field">
          <label style="line-height:33px;">
           <input type="text" class="input w50" name="user.pnumber" " size="20" placeholder="请输入正确手机号" onBlur="CheckPhone(this)" data-validate="required:请输入正确手机号" />
          </label>
        </div>
      </div>      
      <div class="form-group">
        <div class="label">
          <label for="sitename">密码：</label>
        </div>
        <div class="field">
          <input type="password" class="input w50" name="user.upwd" size="20" placeholder="请输入密码"  data-validate="required:请输入密码,length#<=20:密码不少于6位，不多于20位,length#>=6:密码不少于6位，不多于20位" />       
        </div>
      </div>      
      <div class="form-group">
        <div class="label">
          <label for="sitename">姓名：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" name="user.uname" size="20" placeholder="请输入姓名" data-validate="required:请输入用户真实姓名,length#<=10:姓名长度小于等于10位" />       
        </div>
      </div>
      <div class="form-group">
        <div class="label">
          <label for="sitename">性别：</label>
        </div>
        <div class="field">
                          男：<input type="radio" name="user.sex" value="男"/>    女：<input type="radio" name="user.sex"   value="女"/>                              
        </div>
      </div>
      
        <div class="form-group">
        <div class="label">
          <label for="sitename">年龄：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" name="user.age" size="20" placeholder="请输入用户年龄" data-validate="required:请输入年龄,length#<=2:年龄超限" />          
        </div>
      </div>
      
       <div class="form-group">
        <div class="label">
          <label for="sitename">余额</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" name="user.balance" size="20" placeholder="请输入 余额" data-validate="required:请输入账户余额,length#<=5:数额须小于等于99999" />         
        </div>
      </div>
      
      <div class="form-group">
        <div class="label">
          <label></label>
        </div>
        <div class="field">
          <button class="button bg-main icon-check-square-o" type="submit"> 提交</button>   
        </div>
      </div>      
    </form>
  </div>
</div>
 <script>
 function CheckPhone(el){
 var mobile = /^(13[0-9])|(15[0-9])|(16[0-9])|(17[0-9])|(18[0-9])\d{8}$/i;
 if(!mobile.test(el.value))
      alert("不是规范的手机号，请输入正确手机号");
 }
 </script>  
  </body>
</html>
